package com.WOWTradeNews.DataBase;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteDatabase.CursorFactory;
import android.database.sqlite.SQLiteOpenHelper;

public class SystemDBHelper extends SQLiteOpenHelper {
	private static final int DB_VERSION = 1;

	public SystemDBHelper(Context context, String name) {
		super(context, name, null, DB_VERSION);
	}

	@Override
	public void onCreate(SQLiteDatabase db) {
		String sql = "CREATE TABLE IF NOT EXISTS myFavorites" 
				+ "(_id INTEGER PRIMARY KEY AUTOINCREMENT, newsId TEXT, subject TEXT,note TEXT,gjtitle TEXT)";
		db.execSQL(sql);
		sql = "CREATE TABLE IF NOT EXISTS myCoin"
				+ "(myCoin INTEGER)";
		db.execSQL(sql);
//		sql = "INSERT INTO myCoin(myCoin) values(10)";
//		db.execSQL(sql);
	}

	@Override
	public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
		// TODO Auto-generated method stub
		
	}
	
}
